package colbert.content.singleton;

public class LazySingleton {
    private static LazySingleton instance;
    private LazySingleton(){

    }
    public static synchronized LazySingleton getInstance(){
        System.out.println("获取懒汉单例");
       if(instance == null){
           instance = new LazySingleton();
       }
       return instance;
    }

}
